package demo3;

/*
 *  user:38917
 *  date:2025/5/6
 *  time:00:51
 */

public class Test {
    public static void main1(String[] args) {
        Son son = new Son();
    }

    public static void main(String[] args) {
        Father father = new Son();
        father.func();
        System.out.println(father.name);
        Son son = (Son) father;
        System.out.println(son.name);
    }
}
